package com.ityedao.数组;

public class BasicPractice2 {
    public static void main(String[] args) {
        /**
         * 现有一个小数数组{12.9, 53.54, 75.0, 99.1, 3.14}。请编写代码，找出数组中的最小值并打印。
         */
        double[] nums = {12.9, 53.54, 75.0, 99.1, 3.14};

        double min = nums[0];
        for (int i = 1; i < nums.length; i++) {
            if (min > nums[i]){
                min = nums[i];
            }
        }
        System.out.println("最小值为：" + min);
    }
}
